package com.kaiyiweitong.tongxing.activity.my.setting;

import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.widget.GridLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.widget.GridLayout;

import com.kaiyiweitong.tongxing.R;
import com.kaiyiweitong.tongxing.adapter.ServiceAddressAdapter;
import com.kaiyiweitong.tongxing.base.BaseActivity;

import butterknife.Bind;
import butterknife.ButterKnife;
import butterknife.OnClick;

/**
 * Created by Administrator on 2017/12/19 0019.
 */

public class ServiceAddressActivity extends BaseActivity {
    @Bind(R.id.rv_service_address)
    RecyclerView mRvServiceAddress;

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_service_address);
        ButterKnife.bind(this);

        RecyclerView rv_service_address = (RecyclerView) findViewById(R.id.rv_service_address);
        rv_service_address.setLayoutManager(new GridLayoutManager(this, 1, GridLayout.VERTICAL, false));
        ServiceAddressAdapter adapter = new ServiceAddressAdapter(this);
        rv_service_address.setAdapter(adapter);
    }

    @OnClick(R.id.add_adress)
    public void onViewClicked() {
        Intent intent = new Intent(this, SetAddressActivity.class);
        startActivity(intent);
    }
}
